Carbon


SetMenuItemTextEncoding

Header: Menus.h Carbon status: Supported

Sets the text encoding for a menu item’s text.

OSErr SetMenuItemTextEncoding (
    MenuHandle inMenu, 
    SInt16 inItem, 
    TextEncoding inScriptID
);
inMenu

A handle to the menu that contains the menu item whose text encoding you wish to set.

inItem

An integer representing the item number of the menu item.

inScriptID

The script code that corresponds to the text encoding you wish to set.

function result

A result code.

DISCUSSION

To set the text encoding for a menu item’s text, call the SetMenuItemTextEncoding function instead of SetItemCmd. If a menu item has a command code of 0x1C when SetMenuItemTextEncoding is called, the values in the command and icon fields of the menu resource are cleared and replaced with the value in the inScriptID parameter of SetMenuItemTextEncoding.

See also the function GetMenuItemTextEncoding.

VERSION NOTES

This function is available with Appearance Manager 1.0 and later.

AVAILABILITY

Supported in Carbon. Available in CarbonLib 1.0 and later when CarbonLib 1.0 or later is installed. Exported by CarbonLib 1.0 and later and by CarbonLib 1.0 and later.


© 2000 Apple Computer, Inc. — (Last Updated 4/14/2000)